#include "UIManager.h"

UIManager::UIManager(void) : m_Index(0)
{
}

UIManager::~UIManager(void)
{

}

void UIManager::AddStage( Stage* pStage )
{
	m_StageMap[m_Index] = pStage;
	++m_Index;
}

void UIManager::Release()
{
	for(int i = 0; i < m_Index; ++i)
	{
		m_StageMap[i]->Release();
		delete m_StageMap[i];
	}
}

void UIManager::StageFrame( int index )
{
	m_StageMap[index]->Frame();
}

void UIManager::StageRender( int index )
{
	m_StageMap[index]->Render();
}

Board* UIManager::GetFocusBoard()
{
	return m_StageMap[0]->GetFocusBoard();
}

Board* UIManager::GetCapturedBoard()
{
	return m_StageMap[0]->GetCapturedBoard();
}
